import "pkl:test"

const function isGreaterThan(n) = (x) -> x > n

class X {
  a: Int(isGreaterThan(5))
  b: Int(isGreaterThan(10))
}

res1 = new X {
  a = 6
  b = 11
}

res2 = test.catch(() ->
  new X {
    a = 5
  }.a
)
